package com.atguigu.gulimall.search.model.vo;

import com.atguigu.common.model.SkuEsModel;
import lombok.Data;

import java.util.List;

@Data
public class SearchResult {
    //============================分页信息============================
    private Integer pageNum;//当前页码
    private Long total;//总记录数
    private Integer totalPages;//总页码
    private List<Integer> pageNavs;//导航页
    //============================商品信息============================
    /**
     * 所有的商品信息
     */
    private List<SkuEsModel> products;
    //============================搜索选项============================
    /**
     * 当前查询结果所有涉及的品牌
     */
    private List<BrandVO> brands;
    /**
     * 当前查询结果所有涉及的分类
     */
    private List<CatalogVO> catalogs;
    /**
     * 当前查询结果所有涉及的属性及所有的值
     */
    private List<Attrs> attrs;
    //============================面包屑导航============================
    private List<NavVO> navs;
    //============================内部类============================

    @Data
    public static class NavVO {
        private String navName;
        private String navValue;
        private String link;
    }

    @Data
    public static class BrandVO {
        private Long brandId;
        private String brandName;
        private String brandImg;
    }


    @Data
    public static class CatalogVO {
        private Long catalogId;
        private String catalogName;
    }


    @Data
    public static class Attrs {
        private Long attrId;
        private String attrName;
        private List<String> attrValue;
    }
}
